<?php
	require_once "includes/config.php";
	sleep(1);
	$id = $_REQUEST['id'];
	$qry="SELECT * FROM tbl_city where stateid='$id'";
	$res=mysql_query($qry);

		if(mysql_num_rows($res) > 0)
		{
		?>
		 <select name="city" id="city" style="width:60px;  height:27px;" class="inputbg">
		<option value="">City</option>
		<?php
			while($row = mysql_fetch_assoc($res))
			{
			?>
				<option value="<?php echo $row['cityid'] ?>"><?php echo $row['cityname'];?></option>
			<?php		
			}
		?>
		</select>
		<?php
		}			
		else {
		?>  <input type="text" name="city" id="city" style="width:60px;" class="inputbg"> 
		<?php }
		
	?>


